package org.yanex.project.api.parsers;

class FieldConverter {

	static Field getField(String name) {
		String t = name.toLowerCase();
		
		if (t.equals("id")) {
			return Field.ID;
		} else if (t.equals("name")) {
			return Field.NAME;
		} else if (t.equals("category")) {
			return Field.CATEGORY;
		} else if (t.equals("latitude")) {
			return Field.LATITUDE;
		} else if (t.equals("longitude")) {
			return Field.LONGITUDE;
		} else if (t.equals("description")) {
			return Field.DESCRIPTION;
		} else if (t.equals("address")) {
			return Field.ADDRRESS;
		} else if (t.equals("email")) {
			return Field.EMAIL;
		} else if (t.equals("phone")) {
			return Field.PHONE;
		} else 
			return null;
	}
	
}
